package LuoGu.入门.Gold;

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int day = s.nextInt();
        int n = 0;  //用来计数的变量n（记录天数）
        int index = 1;  //存放每轮拿同样钱的天数
        int ans = 0;    //总钱数
        int money = 1; //钱
        while(n!=day){
            for(int i=0;i<index;i++){
                n++;
                ans+=money;
                if(n==day) break;
            }
            index++;
            money++;
        }System.out.println(ans);
    }
}
